package com.lkc.dto;

import com.lkc.entity.SuccessKilled;
import com.lkc.enums.SeckillStatEnum;

/**
 * 封装秒杀执行后的结果
 * @author sgtdunn
 *
 */
public class SeckillExcution {
	private long seckillId;
	//秒杀执行结果状态
	private int state;
	
	//状态的标示
	private String statInfo;
	
	//秒杀成功对象
	private SuccessKilled successKilled;

	public SeckillExcution(long seckillId, SeckillStatEnum statEnum,
			SuccessKilled successKilled) {
		 this.seckillId = seckillId;
	     this.state = statEnum.getState();
	     this.statInfo = statEnum.getStateInfo();
	     this.successKilled = successKilled;
	}
	
	

	public SeckillExcution(long seckillId, SeckillStatEnum statEnum) {
		this.seckillId = seckillId;
	    this.state = statEnum.getState();
	    this.statInfo = statEnum.getStateInfo();
	}



	public long getSeckillId() {
		return seckillId;
	}

	public void setSeckillId(long seckillId) {
		this.seckillId = seckillId;
	}

	public int getState() {
		return state;
	}

	public void setState(int state) {
		this.state = state;
	}

	public String getStatInfo() {
		return statInfo;
	}

	public void setStatInfo(String statInfo) {
		this.statInfo = statInfo;
	}

	public SuccessKilled getSuccessKilled() {
		return successKilled;
	}

	public void setSuccessKilled(SuccessKilled successKilled) {
		this.successKilled = successKilled;
	}
	
	
}
